package com.ashley.day_10;

/**
 * @Author ashley
 * @Date 2019/8/5 20:13
 */
public class CustomersTest {
    public static void main(String[] args) {
        Customers cust = new Customers("Jane", "Smith");

        Account acct = new Account(1000, 2000, 0.0123);
        cust.setAccount(acct);
        cust.getAccount().deposit(100);
        cust.getAccount().withdraw(960);
        cust.getAccount().withdraw(2000);

        System.out.println("Customer [" + cust.getLastName() + "," + cust.getFirstName() + "] has a account: id is " +
                cust.getAccount().getId() + ", annuallnterestRate is " + cust.getAccount().getAnnuallnterestRate() * 100 + "%"
                + ", balance is " + cust.getAccount().getBalance());
    }
}
